package com.sskj.aikeeper.presenter;

import com.lzy.okgo.model.Response;
import com.sskj.aikeeper.bean.CetificationBean;
import com.sskj.aikeeper.hangqing.activity.CertificationResultActivity;
import com.sskj.common.base.HttpData;
import com.sskj.lib.BaseHttpConfig;
import com.sskj.lib.http.JsonCallBack;


/**
 * @author Hey
 * Create at  2019/06/25
 */
public class CertificationResultPresenter extends BasePresenter<CertificationResultActivity> {

    public void getCertificationStatus() {
        httpService.getCertificationStatus()
                .tag(this)
                .execute(new JsonCallBack<HttpData<CetificationBean>>() {
                    @Override
                    public void onSuccess(Response<HttpData<CetificationBean>> response) {
                        if (response.body().status == BaseHttpConfig.OK) {
                            mView.getStatusOK(response.body().getData());
                        }
                    }
                });
    }
}
